import request from "@/utils/request";

//查询合同模板列表
export function getContractList(query) {
  return request({
    url: "/heart/contractTemp/list",
    method: "get",
    params: query,
  });
}

// 提交合同模板
export function saveTemp(data) {
  return request({
    url: "/heart/contractTemp",
    method: "post",
    data,
  });
}


// 合同模板 详情 
export function getDetailContract(query) {
  return request({
    url: '/heart/contractTemp/' + query,
    method: 'get',
  })
}
// 合同模板 修改
export function editContractList(data) {
  return request({
    url: '/heart/contractTemp',
    method: 'put',
    data
  })
}
// 合同模板 删除
export function deleteContractList(query) {
  return request({
    url: '/heart/contractTemp/' + query,
    method: 'delete',
  })
}

// 采购行政合同 查询 1，采购；2，行政
export function getProcureList(query) {
  return request({
    url: '/heart/ContractProcure/list',
    method: 'get',
    params: query
  })
}
// 采购行政合同 新增
export function addProcure(data) {
  return request({
    url: '/heart/ContractProcure',
    method: 'post',
    data
  })
}
// 采购行政合同 详情 
export function getDetailProcure(query) {
  return request({
    url: '/heart/ContractProcure/' + query,
    method: 'get',
  })
}
// 采购行政合同 修改
export function editProcureList(data) {
  return request({
    url: '/heart/ContractProcure',
    method: 'put',
    data
  })
}
// 采购行政合同 删除
export function deleteProcureList(query) {
  return request({
    url: '/heart/ContractProcure/' + query,
    method: 'delete',
  })
}

// 销售合同 查询
export function getSaleList(query) {
  return request({
    url: '/heart/ContractSale/list',
    method: 'get',
    params: query
  })
}
// 销售合同 新增
export function addSaleContract(data) {
  return request({
    url: '/heart/ContractSale',
    method: 'post',
    data
  })
}
// 销售合同 详情 
export function getDetailSale(query) {
  return request({
    url: '/heart/ContractSale/' + query,
    method: 'get',
  })
}
// 销售合同 修改
export function editSaleList(data) {
  return request({
    url: '/heart/ContractSale',
    method: 'put',
    data
  })
}
// 销售合同 删除
export function deleteSaleList(query) {
  return request({
    url: '/heart/ContractSale/' + query,
    method: 'delete',
  })
}

// 盖章管理 查询
export function getSealList(query) {
  return request({
    url: '/heart/SealApply/list',
    method: 'get',
    params: query
  })
}
// 盖章管理 新增
export function addSealContract(data) {
  return request({
    url: '/heart/SealApply',
    method: 'post',
    data
  })
}
// 盖章管理 详情 
export function getDetailSeal(query) {
  return request({
    url: '/heart/SealApply/' + query,
    method: 'get',
  })
}
// 盖章管理 修改
export function editSealList(data) {
  return request({
    url: '/heart/SealApply',
    method: 'put',
    data
  })
}
// 盖章管理 删除
export function deleteSealList(query) {
  return request({
    url: '/heart/SealApply/' + query,
    method: 'delete',
  })
}


// 收款计划 查询
export function getCollectList(query) {
  return request({
    url: '/heart/PlanCollecting/list',
    method: 'get',
    params: query
  })
}
// 收款计划 新增
export function addCollectContract(data) {
  return request({
    url: '/heart/PlanCollecting',
    method: 'post',
    data
  })
}
// 收款计划 详情 
export function getDetailCollect(query) {
  return request({
    url: '/heart/PlanCollecting/' + query,
    method: 'get',
  })
}
// 收款计划 修改
export function editCollectList(data) {
  return request({
    url: '/heart/PlanCollecting',
    method: 'put',
    data
  })
}
// 收款计划 删除
export function deleteCollectList(query) {
  return request({
    url: '/heart/PlanCollecting/' + query,
    method: 'delete',
  })
}

// 开票计划 查询
export function getInvoiceList(query) {
  return request({
    url: '/heart/SupplierInvocie/list',
    method: 'get',
    params: query
  })
}
// 开票计划 新增
export function addInvoiceContract(data) {
  return request({
    url: '/heart/SupplierInvocie',
    method: 'post',
    data
  })
}
// 开票计划 详情 
export function getDetailInvoice(query) {
  return request({
    url: '/heart/SupplierInvocie/' + query,
    method: 'get',
  })
}
// 开票计划 修改
export function editInvoiceList(data) {
  return request({
    url: '/heart/SupplierInvocie',
    method: 'put',
    data
  })
}
// 开票计划 删除
export function deleteInvoiceList(query) {
  return request({
    url: '/heart/SupplierInvocie/' + query,
    method: 'delete',
  })
}

// 工程合同 查询
export function getProjectList(query) {
  return request({
    url: '/heart/ContractProject/list',
    method: 'get',
    params: query
  })
}
// 工程合同 新增
export function addProjectContract(data) {
  return request({
    url: '/heart/ContractProject',
    method: 'post',
    data
  })
}
// 工程合同 详情 
export function getDetailProject(query) {
  return request({
    url: '/heart/ContractProject/' + query,
    method: 'get',
  })
}
// 工程合同 修改
export function editProjectList(data) {
  return request({
    url: '/heart/ContractProject',
    method: 'put',
    data
  })
}
// 工程合同 删除
export function deleteProjectList(query) {
  return request({
    url: '/heart/ContractProject/' + query,
    method: 'delete',
  })
}
